package com.rue89;

import java.util.Date;

import android.content.Context;
import android.graphics.drawable.BitmapDrawable;
import android.os.Parcel;
import android.os.Parcelable;
import android.util.Log;


public class Commentaire {
	
	private String id;
	private String idArticle;
	private String auteur;
	private String image;
	private BitmapDrawable imageDrawable;
	private long datePubli;
	private String contenu;
	private String vote;
	private String nbVote;
	
	public Commentaire() {
		
	}

	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public String getIdArticle() {
		return idArticle;
	}

	public void setIdArticle(String idArticle) {
		this.idArticle = idArticle;
	}

	public String getAuteur() {
		return auteur;
	}

	public void setAuteur(String auteur) {
		this.auteur = auteur;
	}

	public String getImage() {
		return image;
	}

	public void setImage(String image, Context ctx, boolean charge) {
		this.image = image;
		if (charge)
			this.setImageDrawable(Tools.downloadVignette(image, this.auteur, ctx));
			
	}

	public BitmapDrawable getImageDrawable() {
		return imageDrawable;
	}

	public void setImageDrawable(BitmapDrawable imageDrawable) {
		this.imageDrawable = imageDrawable;
	}

	public long getDatePubli() {
		return datePubli;
	}

	public void setDatePubli(Long datePubli) {
		this.datePubli = datePubli;
	}

	public String getContenu() {
		return contenu;
	}

	public void setContenu(String contenu) {
		this.contenu = contenu;
	}

	public String getVote() {
		return vote;
	}

	public void setVote(String vote) {
		this.vote = vote;
	}

	public String getNbVote() {
		return nbVote;
	}

	public void setNbVote(String nbVote) {
		this.nbVote = nbVote;
	}

	
}
